css: Fix printing code for CSS strings and idents
authorBenjamin Otte <otte@redhat.com>
Thu, 1 May 2014 17:48:40 +0000 (19:48 +0200)
committerBenjamin Otte <otte@redhat.com>
Mon, 5 May 2014 13:48:02 +0000 (15:48 +0200)
It used to infloop on special characters.

gtk/gtkcssparser.c
gtk/gtkcssstringvalue.c

index 16505a320e738884299c0906ef1a1ad93c199a38..de78ae6fb10f32e2c77407e698afe2a5bdeed361 100644 (file)
@@ -1051,6 +1051,7 @@ _gtk_css_print_string (GString    *str,
         g_assert_not_reached ();
         break;
       }
+    string++;
   } while (*string);
 
   g_string_append_c (str, '"');
index 11a893af8382ab69a0d2ccecccf0c5deef4fdf93..5da9fefbcc19b1b7512ad130d038ed229d1da07f 100644 (file)
@@ -111,6 +111,7 @@ gtk_css_value_ident_print (const GtkCssValue *value,
         g_assert_not_reached ();
         break;
       }
+    string++;
   } while (*string);
 }